/PROG  PNS0067
/ATTR
OWNER		= MNEDITOR;
COMMENT		= "53332389/90";
PROG_SIZE	= 3354;
CREATE		= DATE 18-05-25  TIME 09:16:02;
MODIFIED	= DATE 25-04-29  TIME 18:33:46;
FILE_NAME	= PNS0042;
VERSION		= 0;
LINE_COUNT	= 120;
MEMORY_SIZE	= 3810;
PROTECT		= READ_WRITE;
TCD:  STACK_SIZE	= 0,
      TASK_PRIORITY	= 50,
      TIME_SLICE	= 0,
      BUSY_LAMP_OFF	= 0,
      ABORT_REQUEST	= 0,
      PAUSE_REQUEST	= 0;
DEFAULT_GROUP	= 1,*,*,*,*;
CONTROL_CODE	= 00000000 00000000;
/APPL
/MN
   1:  !******************************** ;
   2:  !     COSMA METAL FORMING  ;
   3:  !******************************** ;
   4:  !  LINE: CHINA CHANGSHA ;
   5:  !  ROBOT: R23 ;
   6:  !  PROGRAM: PNS0042 ;
   7:  !  PART:53332389/90  ;
   8:  !******************************** ;
   9:   ;
  10:  !INITIALIZE ;
  11:  OVERRIDE=20% ;
  12:  MOVE TO HOME    ;
  13:  R[14]=90    ;
  14:  R[18]=1    ;
  15:  R[19]=.2    ;
  16:   ;
  17:  !------------------------------- ;
  18:  !BEGINNING OF PROGRAM ;
  19:  CALL PARTDROP    ;
  20:  COL GUARD ADJUST R[14] ;
  21:  UTOOL_NUM=1 ;
  22:  UFRAME_NUM=0 ;
  23:  PAYLOAD[3] ;
  24:  R[5]=10    ;
  25:  OVERRIDE=R[5] ;
  26:  !INITIATE TO PICK-POUNCE ;
  27:J P[1:MIDDLE] 50% CNT100 ACC100    ;
  28:J P[2:PICK POUNCE] 50% CNT100 ACC100    ;
  29:  PAUSE ;
  30:  R[1]=0    ;
  31:  TIMER[1]=RESET ;
  32:  TIMER[1]=START ;
  33:   ;
  34:  LBL[10:TOP OF LOOF] ;
  35:  OVERRIDE=R[5] ;
  36:   ;
  37:  TIMER[3]=STOP ;
  38:  TIMER[2]=STOP ;
  39:  R[1]=R[1]+1    ;
  40:  R[2]=TIMER[2]    ;
  41:  R[3]=60/R[2]    ;
  42:  R[8]=TIMER[3]    ;
  43:  TIMER[2]=RESET ;
  44:  TIMER[2]=START ;
  45:  TIMER[3]=RESET ;
  46:   ;
  47:  !PROCEED TO PICK ;
  48:  LBL[20] ;
  49:  IF DI[1]=ON AND DI[3]=ON AND DI[8]=ON,JMP LBL[25] ;
  50:  IF DI[29]=ON,JMP LBL[90] ;
  51:  JMP LBL[20] ;
  52:   ;
  53:  LBL[25] ;
  54:  TIMER[3]=START ;
  55:  R[5]=100    ;
  56:  OVERRIDE=R[5] ;
  57:J P[3:PICK APPROACH] 100% CNT100 ACC100    ;
  58:   ;
  59:J P[4:PICK] 80% CNT5 TB R[18]sec,CALL PARTPICK ACC100    ;
  60:  PAYLOAD[4] ;
  61:  CALL CHK_PICK    ;
  62:  MONITOR Z_CHECH ;
  63:J P[5:PICK DEPART] 80% CNT60 ACC100 TA R[20]sec,DO[5]=PULSE,1.0sec    ;
  64:  DO[8]=PULSE,1.0sec ;
  65:  LBL[27] ;
  66:  CALL CHECKPICK    ;
  67:  IF DI[9]=OFF OR DI[11]=OFF,JMP LBL[27] ;
  68:   ;
  69:   ;
  70:J P[7:PICK CLEAR] 100% CNT100 ACC100    ;
  71:   ;
  72:  LBL[30:GOTO DROP POUNCE] ;
  73:J P[8:DROP POUNCE] 100% CNT100 ACC100 BREAK    ;
  74:   ;
  75:  TIMER[3]=STOP ;
  76:  LBL[40:AT DROP POUNCE] ;
  77:  IF DI[2]=ON AND DI[4]=ON AND DI[5]=ON,JMP LBL[80] ;
  78:  IF DI[7]=ON AND DI[2]=ON,JMP LBL[50] ;
  79:  IF DI[18]=ON,JMP LBL[60] ;
  80:  JMP LBL[40] ;
  81:   ;
  82:  LBL[50:MOVE DROP SNEAK] ;
  83:  TIMER[3]=START ;
  84:  OVERRIDE=R[5] ;
  85:J P[9:DROP SNEAK] 100% CNT100 ACC100 BREAK    ;
  86:  LBL[51:DROP OR C-P-S] ;
  87:  IF DI[2]=ON AND DI[4]=ON AND DI[5]=ON,JMP LBL[80] ;
  88:  IF DI[18]=ON,JMP LBL[40] ;
  89:  JMP LBL[51] ;
  90:  JMP LBL[50] ;
  91:   ;
  92:  LBL[60:MOVE CLS-PRS-ACC] ;
  93:J P[1:MIDDLE] 50% CNT100 ACC100    ;
  94:  PAUSE ;
  95:  JMP LBL[30] ;
  96:   ;
  97:  LBL[80:DROP ENABLED] ;
  98:  TIMER[3]=START ;
  99:  !PROCEED TO DROP ;
 100:  OVERRIDE=R[5] ;
 101:J P[10:DROP APPROACH] 100% CNT50 ACC100    ;
 102:  MONITOR END Z_CHECH ;
 103:J P[11:DROP] 100% CNT10 TB R[19]sec,CALL PARTDROP ACC110    ;
 104:  DO[6]=PULSE,1.0sec ;
 105:  PAYLOAD[3] ;
 106:  CALL CHK_DROP    ;
 107:J P[12:DROP DEPART] 100% CNT100 ACC130 TA    .01sec,DO[7]=PULSE,1.0sec    ;
 108:J P[13:DROP CLEAR] 100% CNT100 ACC130    ;
 109:  !GOTO PICK POUNCE ;
 110:J P[2:PICK POUNCE] 100% CNT100 ACC100 BREAK    ;
 111:  IF DI[29]=ON,JMP LBL[90] ;
 112:  JMP LBL[10] ;
 113:   ;
 114:  LBL[90:END OF CYCLE] ;
 115:  TIMER[1]=STOP ;
 116:  R[4]=TIMER[1]    ;
 117:J P[1:MIDDLE] 50% CNT100    ;
 118:  MOVE TO HOME    ;
 119:   ;
 120:  LBL[100:END OF PROGRAM] ;
/POS
P[1:"MIDDLE"]{
   GP1:
	UF : 0, UT : 1,		CONFIG : 'N U T, 0, 0, 1',
	X =  2086.456  mm,	Y =     -.007  mm,	Z =  -830.000  mm,
	W =  -180.000 deg,	P =     -.000 deg,	R =  -180.000 deg,
	E1=   107.700 deg
};
P[2:"PICK POUNCE"]{
   GP1:
	UF : 0, UT : 1,		CONFIG : 'N U T, 0, 0, 0',
	X =  2113.283  mm,	Y =  1525.811  mm,	Z =  -961.060  mm,
	W =   177.879 deg,	P =     4.132 deg,	R =   147.047 deg,
	E1=   137.131 deg
};
P[3:"PICK APPROACH"]{
   GP1:
	UF : 0, UT : 1,		CONFIG : 'N U T, 0, 0, 0',
	X =  2552.973  mm,	Y =  3265.290  mm,	Z =  -945.666  mm,
	W =  -179.983 deg,	P =     -.471 deg,	R =    89.874 deg,
	E1=   193.385 deg
};
P[4:"PICK"]{
   GP1:
	UF : 0, UT : 1,		CONFIG : 'N U T, 0, 0, 0',
	X =  2552.972  mm,	Y =  3265.289  mm,	Z = -1130.947  mm,
	W =  -179.983 deg,	P =     -.471 deg,	R =    89.874 deg,
	E1=   193.385 deg
};
P[5:"PICK DEPART"]{
   GP1:
	UF : 0, UT : 1,		CONFIG : 'N U T, 0, 0, 0',
	X =  2552.973  mm,	Y =  3265.290  mm,	Z = -1034.626  mm,
	W =  -179.983 deg,	P =     -.471 deg,	R =    89.874 deg,
	E1=   193.385 deg
};
P[7:"PICK CLEAR"]{
   GP1:
	UF : 0, UT : 1,		CONFIG : 'N U T, 0, 0, 0',
	X =  2155.467  mm,	Y =  1431.281  mm,	Z =  -877.848  mm,
	W =  -179.063 deg,	P =     -.079 deg,	R =   146.228 deg,
	E1=   138.045 deg
};
P[8:"DROP POUNCE"]{
   GP1:
	UF : 0, UT : 1,		CONFIG : 'N U T, 0, 0, 1',
	X =  2048.563  mm,	Y =  -932.967  mm,	Z = -1008.719  mm,
	W =  -178.096 deg,	P =     1.000 deg,	R =  -157.691 deg,
	E1=    82.388 deg
};
P[9:"DROP SNEAK"]{
   GP1:
	UF : 0, UT : 1,		CONFIG : 'N U T, 0, 0, 1',
	X =  2185.155  mm,	Y = -1747.259  mm,	Z = -1012.792  mm,
	W =  -177.596 deg,	P =     1.485 deg,	R =  -138.761 deg,
	E1=    63.392 deg
};
P[10:"DROP APPROACH"]{
   GP1:
	UF : 0, UT : 1,		CONFIG : 'N U T, 0, 0, 1',
	X =  2602.436  mm,	Y = -3267.501  mm,	Z = -1006.067  mm,
	W =  -174.583 deg,	P =    -4.040 deg,	R =   -92.237 deg,
	E1=    15.239 deg
};
P[11:"DROP"]{
   GP1:
	UF : 0, UT : 1,		CONFIG : 'N U T, 0, 0, 1',
	X =  2602.435  mm,	Y = -3267.501  mm,	Z = -1204.148  mm,
	W =  -174.583 deg,	P =    -4.040 deg,	R =   -92.237 deg,
	E1=    15.239 deg
};
P[12:"DROP DEPART"]{
   GP1:
	UF : 0, UT : 1,		CONFIG : 'N U T, 0, 0, 1',
	X =  2602.435  mm,	Y = -3267.501  mm,	Z = -1127.027  mm,
	W =  -174.583 deg,	P =    -4.040 deg,	R =   -92.237 deg,
	E1=    15.239 deg
};
P[13:"DROP CLEAR"]{
   GP1:
	UF : 0, UT : 1,		CONFIG : 'N U T, 0, 0, 1',
	X =  2196.045  mm,	Y = -1707.915  mm,	Z = -1090.856  mm,
	W =  -176.246 deg,	P =     3.424 deg,	R =  -138.326 deg,
	E1=    62.713 deg
};
/END
